
<%@ page import="rentadomus.Person" %>
<!DOCTYPE html>
<html>
  <head>
    <meta name="layout" content="main">
  <g:set var="entityName" value="${message(code: 'person.label', default: 'Person')}" />
  <title><g:message code="default.show.label" args="[entityName]" /></title>
</head>
<body>
  <a href="#show-person" class="skip" tabindex="-1"><g:message code="default.link.skip.label" default="Skip to content&hellip;"/></a>
  <div class="nav" role="navigation">
    <ul>
      <li><a class="home" href="${createLink(uri: '/')}"><g:message code="default.home.label"/></a></li>
    </ul>
  </div>
  <div id="show-person" class="content scaffold-show" role="main">
    <h1>RentADomus profile</h1>
    <g:if test="${flash.message}">
      <div class="message" role="status">${flash.message}</div>
    </g:if>
    <ol class="property-list person">
      
      <g:if test="${personInstance?.identificationType}">
        <li class="fieldcontain">
          <span id="identificationType-label" class="property-label"><g:message code="person.identificationType.label" default="Identification Type" /></span>

          <span class="property-value" aria-labelledby="identificationType-label">${personInstance?.identificationType?.encodeAsHTML()}</span>

        </li>
      </g:if>

      <g:if test="${personInstance?.identification}">
        <li class="fieldcontain">
          <span id="identification-label" class="property-label"><g:message code="person.identification.label" default="Identification number" /></span>

          <span class="property-value" aria-labelledby="identification-label"><g:fieldValue bean="${personInstance}" field="identification"/></span>

        </li>
      </g:if>

      <g:if test="${personInstance?.name}">
        <li class="fieldcontain">
          <span id="name-label" class="property-label"><g:message code="person.name.label" default="Name" /></span>

          <span class="property-value" aria-labelledby="name-label"><g:fieldValue bean="${personInstance}" field="name"/></span>

        </li>
      </g:if>

      <g:if test="${personInstance?.lastName}">
        <li class="fieldcontain">
          <span id="lastName-label" class="property-label"><g:message code="person.lastName.label" default="Last Name" /></span>

          <span class="property-value" aria-labelledby="lastName-label"><g:fieldValue bean="${personInstance}" field="lastName"/></span>

        </li>
      </g:if>

      <g:if test="${personInstance?.email}">
        <li class="fieldcontain">
          <span id="email-label" class="property-label"><g:message code="person.email.label" default="Email" /></span>

          <span class="property-value" aria-labelledby="email-label"><g:fieldValue bean="${personInstance}" field="email"/></span>

        </li>
      </g:if>
      
      <g:if test="${personInstance?.address}">
        <li class="fieldcontain">
          <span id="address-label" class="property-label"><g:message code="person.address.label" default="Address" /></span>

          <span class="property-value" aria-labelledby="address-label"><g:fieldValue bean="${personInstance}" field="address"/></span>

        </li>
      </g:if>

      <g:if test="${personInstance?.username}">
        <li class="fieldcontain">
          <span id="username-label" class="property-label"><g:message code="person.username.label" default="Username" /></span>

          <span class="property-value" aria-labelledby="username-label"><g:fieldValue bean="${personInstance}" field="username"/></span>

        </li>
      </g:if>
      <g:if test="${phones}">
      <li class="fieldcontain">
        <span id="rules-label" class="property-label">Phones</span>

      <g:each in="${phones}" var="phone">
        <span class="property-value" aria-labelledby="phone-label"><g controller="phone" action="show" id="${phone.id}">${phone?.encodeAsHTML()}</g></span>
      </g:each>
    </li>
    </g:if>
    </ol>
    <g:form>
      <fieldset class="buttons">
        <g:hiddenField name="id" value="${personInstance?.id}" />
        <g:if test="${session.person.id == personInstance?.id}">
          <g:link class="edit" action="edit" id="${personInstance?.id}"><g:message code="default.button.edit.label" default="Edit" /></g:link>
        </g:if>
      </fieldset>
    </g:form>
  </div>
</body>
</html>